<?php
	session_start();
	
	require_once('../../lib/'.'BaseDir.inc.htm');
	require_once (EIU_LIB.'View.class.htm');
	require_once(EIU_LIB.'DBCommon.class.htm');
	
	if(!empty($_POST['costID'])){
		$oDB = new DBCommon();
		$conn =  $oDB->stl_openConn();
		
		$q = "
			SELECT ID,CostName,Amount,CostCode,isDeleted,CreateDate,LastUpdate,ModifiedBy,Remark 
			FROM cost_tbl 
			WHERE ID='".$_POST['costID']."' AND isDeleted = 0;";
		
		//echo $q;
		
		$rs = $oDB->stl_db_select($q, $conn);
		
		echo json_encode($rs);
		
		$oDB->stl_closeConn($conn);
	}
?>
